import { getRequest, postRequest, putRequest, deleteRequest } from '@/utils/request';
/**
 * 月末报工
 * */
// 创建
export const productionPrdMonthReportCreate = (data) => postRequest('/production/prd-month-report/create', data);

// 更新
export const productionPrdMonthReportUpdate = (data) => putRequest('/production/prd-month-report/update', data);

// 删除
export const productionPrdMonthReportDelete = (params) => deleteRequest('/production/prd-month-report/delete', params);

// 获得
export const productionPrdMonthReportGet = (params) => getRequest('/production/prd-month-report/get', params);

// 获得分页
export const productionPrdMonthReportPage = (params) => getRequest('/production/prd-month-report/page', params);

// 导出 Excel
export const productionPrdMonthReportExportExcel = (params) => getRequest('/production/prd-month-report/export-excel', params);

// 提交
export const productionPrdMonthReportSubmitAudit = (params) => postRequest('/production/prd-month-report/submit-audit', params);
// 撤销提交
export const productionPrdMonthReportClearSubmitAudit = (params) => postRequest('/production/prd-month-report/clear-submit-audit', params);
// 审核
export const productionPrdMonthReportAudit = (params) => postRequest('/production/prd-month-report/audit', params);
// 撤销审核
export const productionPrdMonthReportClearAudit = (params) => postRequest('/production/prd-month-report/clear-audit', params);
// 保存并审核
export const productionPrdMonthReportCreateAudit = (params) => postRequest('/production/prd-month-report/create-audit', params);
// 更新并审核
export const productionPrdMonthReportUpdateAudit = (params) => putRequest('/production/prd-month-report/update-audit', params);
// 关闭
export const productionPrdMonthReportClose = (params) => postRequest('/production/prd-month-report/close', params);
// 撤销关闭
export const productionPrdMonthReportClearClose = (params) => postRequest('/production/prd-month-report/clear-close', params);
export const productionPrdMachinePage = (params) => getRequest('/production/prd-machine/page', params);

// 下达与撤回
export const productionPrdMonthReportRelease = (params) => postRequest('/production/prd-month-report/release', params);
export const productionPrdMonthReportClearRelease = (params) => postRequest('/production/prd-month-report/clear-release', params);

export const productionPrdMonthReportGetDate = (params) => getRequest('/production/prd-month-report/getDate', params);
export const productionPrdMonthReportUpdateStatus = (params) => postRequest('/production/prd-month-report/update-status', params);

// 版本记录
export const productionPrdMonthReportHistoryPage = (params) => getRequest('/production/prd-month-report/history-page', params);
export const productionPrdMonthReportHistoryGet = (params) => getRequest('/production/prd-month-report/history-get', params);
export const iotCollectDataLtPage = (params) => getRequest('/iot/collect-data/lt-page', params);
// 将历史版本设置为主版本
export const productionPrdMonthReportHistorySetMaster = (data, params) => postRequest('/production/prd-month-report/history/set-master', data, params);

export const productionPrdMonthReportLtGetDate = (params) => getRequest('/production/prd-month-report/lt/getDate', params);

// 切疵报表(实时)
export const iotCollectDataLtCutPage = (params) => getRequest('/iot/collect-data/lt-cut-page', params);
export const iotCollectDataLtCutSignalInfo = (params) => getRequest('/iot/collect-data/lt-cut-signal-info', params);

export const productionPrdMonthReportFixDate = (params) => postRequest('/production/prd-month-report/fixDate', params);
export const krGetWeakReportPage = (params) => getRequest('/kr/getWeakReportPage', params);
export const krGetDoffDataPage = (params) => getRequest('/kr/getDoffDataPage', params);
export const krGetMachineInfoList = (params) => getRequest('/kr/getMachineInfoList', params);
export const spinReportGetBreakData = (params) => getRequest('/spinreport/getBreakData', params);
export const spinReportGetSpindlesData = (params) => getRequest('/spinreport/getSpindlesData', params);
export const spinReportSpindlesReportGetSpindlesData = (params) => getRequest('/spinreport/spindlesReport/getSpindlesData', params);
export const spinReportGetPageBreaksBySpindle = (params) => getRequest('/spinreport/getPageBreaksBySpindle', params);
export const spinReportGetPageDetails = (params) => getRequest('/spinreport/getPageDetails', params);
